From: cl349@firebug.cl.cam.ac.uk Date: Thu, 15 Sep 2005 18:39:17 +0000 (+0000) Subject: Export block device read-only state into store. X-Git-Tag: archive/raspbian/4.8.0-1+rpi1~1^2~16780^2~66 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=5d7ce7cc39733cef83e2a71d8aa6919942d1fb3b;p=xen.git Export block device read-only state into store. Signed-off-by: Christian Limpach --- diff --git a/tools/python/xen/xend/XendDomainInfo.py b/tools/python/xen/xend/XendDomainInfo.py index 01ac58ac9d..584bc205b0 100644 --- a/tools/python/xen/xend/XendDomainInfo.py +++ b/tools/python/xen/xend/XendDomainInfo.py @@ -422,10 +422,13 @@ class XendDomainInfo: (type, params) = string.split(sxp.child_value(devconfig, 'uname'), ':', 1) + readonly = sxp.child_value(devconfig, 'mode', 'r') back = { 'type' : type, 'params' : params, 'frontend' : frontpath, 'frontend-id' : "%i" % self.domid } + if readonly == 'r': + back['read-only'] = "" # existence indicates read-only xstransact.Write(backpath, back) return